<html><head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width">
<title>2020高考备考讲座 听课效果调查问卷</title>
<meta name="Keywords" content="">
<meta name="Description" content="">
<meta name="viewport" content="initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
<link rel="stylesheet" type="text/css" href="http://tmall.fc62.com/mobile/themesmobile/68ecshopcom_mobile/css/zhaomu.css"/>
<link rel="stylesheet" type="text/css" href="http://tmall.fc62.com/mobile/themesmobile/68ecshopcom_mobile/css/questionnaire.css"/>
<script type="text/javascript" src="http://tmall.fc62.com/mobile/themesmobile/68ecshopcom_mobile/js/layer_mobile/layer.js"></script>
<link rel="stylesheet" type="text/css" href="http://tmall.fc62.com/mobile/themesmobile/68ecshopcom_mobile/css/layer.css" />
<script src="http://tmall.fc62.com/mobile/themesmobile/68ecshopcom_mobile/js/jquery.1.9.1.js"></script>
<script type="text/javascript" src="http://tmall.fc62.com/mobile/themesmobile/68ecshopcom_mobile/js/rem.js"></script>
<script type="text/javascript" src="http://tmall.fc62.com/mobile/themesmobile/68ecshopcom_mobile/js/address_select/mobileSelect.js"></script>
<link rel="stylesheet" type="text/css" href="http://tmall.fc62.com/mobile/themesmobile/68ecshopcom_mobile/js/address_select/mobileSelect.css" />
</head>
<body class="body_tj">
<div id="tbh5v0">
<img style="width: 100%;" src="http://tmall.fc62.com/mobile/themesmobile/68ecshopcom_mobile/images/question_top.jpg"/>
<ul class="question">
	<li>
		<p>1. 您参加的讲座主题是哪一个您参加的讲座主题是哪一个 <span style="color: #ff0000;">*</span></p>
		<p>
			<input type="radio" name="wenjuan1" id="a1" value="A" />
			<label for="a1"><span>A. 直击高考语文备考</span></label>
		</p>
		<p>
			<input type="radio" name="wenjuan1" id="b1" value="B"  />
			<label for="b1"><span>B. 2020高考语文的新趋势</span></label>
		</p>
		<p>
			<input type="radio" name="wenjuan1" id="c1" value="C"  />
			<label for="c1"><span>C. 疫情下，如何在2020高考中取胜</span></label>
		</p>	
	</li>
	<li>
		<p>1. 您参加的讲座主题是哪一个您参加的讲座主题是哪一个 <span style="color: #ff0000;">*</span></p>
		<p>
			<input type="checkbox" name="wenjuan2" id="a2" value="A" />
			<label class="checkbox-label" for="a2"><span>A. 直击高考语文备考</span></label>
		</p>
		<p>
			<input type="checkbox" name="wenjuan2" id="b2" value="B"  />
			<label class="checkbox-label" for="b2"><span>B. 2020高考语文的新趋势</span></label>
		</p>
		<p>
			<input type="checkbox" name="wenjuan2" id="c2" value="C"  />
			<label class="checkbox-label" for="c2"><span>C. 疫情下，如何在2020高考中取胜</span></label>
		</p>	
	</li>
	<li>
		<p>1. 您参加的讲座主题是哪一个 <span style="color: #ff0000;">*</span></p>
		<p>
			<input type="text" name="wenjuan3" value="" style="text-indent: 0.2rem;" />
		</p>
	</li>
</ul>
<div class="question_btn">
 	<input type="submit" value="提 交" class="question_submit">
</div>
<div class="question_mid">
	<div>
		<p>《考前30天突破卷·语文》电子版 </p>
		<a href="javascript:;">立即查看</a>
	</div>
</div>
<script>
$(function(){
	$('.question_submit').click(function(){
		var wenjuan1 = $("input[name='wenjuan1']:checked").val();
		var wenjuan2 = "";
		$("input[name='wenjuan2']:checked").each(function(){
			wenjuan2 += $(this).val() + ","; 
		});
		if(wenjuan2.length > 0){
			wenjuan2 = wenjuan2.substring(0, wenjuan2.length - 1); //把最后一个逗号去掉
		}
		var wenjuan3 = $("input[name='wenjuan3']").val();
		if(wenjuan1 == ""||wenjuan1 == null){
			layer.open({
				content: '请作答',
				skin: 'msg',
				time: 2 //2秒后自动关闭
			});
			return false;
		}
		if(wenjuan2 == ""||wenjuan2 == null){
			layer.open({
				content: '请作答',
				skin: 'msg',
				time: 2 //2秒后自动关闭
			});
			return false;
		}
		if(wenjuan3 == ""||wenjuan3 == null){
			layer.open({
				content: '请作答',
				skin: 'msg',
				time: 2 //2秒后自动关闭
			});
			return false;
		}
		$.ajax({
			type: 'post',
			url:"" , 
			data:{wenjuan1:wenjuan1,wenjuan2:wenjuan2,wenjuan3:wenjuan3},
			success: function(data){
				if(data.code == 0){
		            layer.open({
		              content: data.msg,//您未认真听讲或未认真答题，请重新答题
		              skin: 'msg',
		              time: 2,
		            });
		            return false;
		         }else{
		         	$('.addressmone').show();
		         	$('.question_mid a').css('color','#001f6e');
		         	$('.question_mid a').attr('href','https://www.baidu.com/');
		         }
			}
		});
	});
});
</script>
<div class="addressmone">
	<ul>
	   <li>
		 <h1 class="form_top">如需纸质版,填写领取寄送地址 </h1>
		 <p style="color: #ff0000;">* 免收邮寄费</p>
	   </li>
	   <li>
		 <p class="form_con">联系人 <span style="color: #ff0000;">*</span></p>
		 <input type="text" name="consignee" value="" id="name" >
		 <img src="http://tmall.fc62.com/mobile/themesmobile/68ecshopcom_mobile/images/form_03.jpg"/>
	   </li>
	   <li>
		 <p class="form_con">联系电话 <span style="color: #ff0000;">*</span></p>
		 <input type="number" pattern="[0-9]*" name="" id="tel" value="" />
		 <img style="bottom: 0.9rem;" src="http://tmall.fc62.com/mobile/themesmobile/68ecshopcom_mobile/images/form_06.jpg"/>
		 <input style="width: 59%;" type="number" name="" id="code" pattern="[0-9]*" value="" />
		 <div class="huoqu">获取验证码</div>
		 <img src="http://tmall.fc62.com/mobile/themesmobile/68ecshopcom_mobile/images/form_01.png"/>
		</li>
		<li style="position: relative;">
		 <p class="form_con">所在地区 <span style="color: #ff0000;">*</span></p>
		 <div id="trigger4" class="trigger4" style="text-indent:0.5em;display: inline-block;border: 1px solid #ccc;width: 100%;height: 35px;line-height: 35px;border-radius: 5px;overflow: hidden;">
			<span style="color: #666;">请选择</span>
		 </div>
		 <img style="position: absolute;bottom: 0.3rem;left: 92%;width: 0.26rem;height: 0.13rem;" src="http://tmall.fc62.com/mobile/themesmobile/68ecshopcom_mobile/images/tj.png"/>
		 <input type="hidden" name="" id="sheng" value="" />
		 <input type="hidden" name="" id="shi" value="" />
		 <input type="hidden" name="" id="xian" value="" />
	  </li>
	  <li>
	  	<p class="form_con">详细地址 <span style="color: #ff0000;">*</span></p>
    		 <textarea name="address" id="address"></textarea>
	   </li>
    	</ul>
            
     <div class="dotm_btn">
     	<input type="submit" value="提 交" class="dotm_btn1">
     </div>

</div>
</div>

<script>
	$(function(){
		var mobileSelect4 = new MobileSelect({
		    trigger: '#trigger4',
		    title: '地区选择',
		    wheels: [{data:[
		    					{
	                            id:'1',
	                            value:'',
	                            childs:[
	                                {id:'A1',value:''},
	                            ]
	                        }
		    			]}],
			 transitionEnd:function(indexArr, data){
			        
			 },
			 callback:function(indexArr, data){
			 	console.log(data);
			    $('#sheng').val(data[0].id);
			    $('#shi').val(data[1].id);
			    $('#xian').val(data[2].id);
			 }  
		});
		 $.ajax({
	        type: "get",
	        url: "http://oa.fc62.com/api/ajax/area",
	        dataType: "json",
	        success: function(res){
	            mobileSelect4.updateWheels(res.data);
	        }
	  });
	  $('.huoqu').click(function() {
			var tel = $('#tel').val();
			if(!(/^1[3456789]\d{9}$/.test(tel))) {
				layer.open({
					content: '请输入正确的手机号码',
					skin: 'msg',
					time: 2 //2秒后自动关闭
				});
				return false;
			}
//			验证手机号
			$.ajax({
				type: 'get',
				url:"http://oa.fc62.com/api/Activity/tel/tel/"+tel , 
				success: function(data){
					if(data.code == 0){
						layer.open({
							content:data.msg ,
							skin: 'msg',
							time: 2 //2秒后自动关闭
						});
						return false
					}else{
//						发送验证码
						$.ajax({
							type: 'post',
							url:"http://oa.fc62.com/api/sms/send" ,
							data:{mobile:tel,action:'default'},
							success: function(data){
								if(data.code != 1){
									layer.open({
										content:data.msg ,
										skin: 'msg',
										time: 2 //2秒后自动关闭
									});
									return false
								}else{
									var count = 120;
								    const countDown = setInterval(() => {
								      if (count === 0) {
								       $('.huoqu').text('重新发送').removeAttr('disabled');
								       $('.huoqu').css({
								        background: '#f3494c',
								        color: '#fff',
								       });
								       clearInterval(countDown);
								      } else {
								       $('.huoqu').attr('disabled', true);
								       $('.huoqu').css({
								        background: '#eee',
								        color: '#333',
								       });
								       $('.huoqu').text(count + '秒后可重新获取');
								      }
								      count--;
								     }, 1000);
								}
							}
						})
									
					}
				}
			});
		  });
	  	$('.dotm_btn1').click(function(){
	  		var sheng = $('#sheng').val();
			var shi = $('#shi').val();
			var xian = $('#xian').val();
			var name = $('#name').val();
			var tel = $('#tel').val();
			var address = $('#address').val();
			if(sheng == ""||sheng == null){
				layer.open({
					content: '请选择所在地区',
					skin: 'msg',
					time: 2 //2秒后自动关闭
				});
				return false;
			}
			if(name == ""||name == null){
				layer.open({
					content: '请填写姓名',
					skin: 'msg',
					time: 2 //2秒后自动关闭
				});
				return false;
			}
			
			if(!(/^1[3456789]\d{9}$/.test(tel))) {
				layer.open({
					content: '请输入正确的手机号码',
					skin: 'msg',
					time: 2 //2秒后自动关闭
				});
				return false;
			}
			if(address == ""||address == null){
				layer.open({
					content: '请填写详细地址',
					skin: 'msg',
					time: 2 //2秒后自动关闭
				});
				return false;
			}
	        //验证验证码
		      $.ajax({
		        type: 'post',
		        url:"http://oa.fc62.com/api/sms/check" ,
		        data:{mobile:tel,captcha:code},
		        success: function(data){
		          if(data.code == 0){
		            layer.open({
		              content: data.msg,
		              skin: 'msg',
		              time: 2,
		            });
		            return false;
		          }else{
//		          		提交表单
						$.ajax({
							type: 'post',
							url:"" , 
							data:{sheng:sheng,shi:shi,xian:xian,name:name,tel:tel,address:address},
							success: function(data){
								if(data.code == 0){
						            layer.open({
						              content: data.msg,
						              skin: 'msg',
						              time: 2,
						            });
						            return false;
						         }else{
									window.location.href="http://tmall.fc62.com/hblq_success.html"; 
						         }

							}
						});
					}
				  }
		       });
		});
					
	});
</script>
</body>

</html>